<?php

namespace Admin\Entity;

use Admin\Entity\Profile;

class User extends Profile {

    public $userID;
    public $roleID;
    public $userName;

    public function getUserID() {
        return $this->userID;
    }

    public function setUserID($userID) {
        $this->userID = $userID;
    }

    public function getRoleId() {
        return $this->roleID;
    }

    public function setRoleId($roleID) {
        $this->roleID = $roleID;
    }

    public function getUserName() {
        return $this->userName;
    }

    public function setUserName($userName) {
        $this->userName = $userName;
    }

    public function setDataUser($data) {
        $this->userID = (isset($data['userID'])) ? $data['userID'] : null;
        $this->roleID = (isset($data['roleID'])) ? $data['roleID'] : null;
        $this->userName = (isset($data['userName'])) ? $data['userName'] : null;
        $this->password = (isset($data['password'])) ? $data['password'] : null;
        $this->fullName = (isset($data['fullName'])) ? $data['fullName'] : null;
        $this->lastName = (isset($data['lastName'])) ? $data['lastName'] : null;
        $this->sex = (isset($data['sex'])) ? $data['sex'] : null;
        $this->birthday = (isset($data['birthday'])) ? $data['birthday'] : null;
        $this->email = (isset($data['email'])) ? $data['email'] : null;
        $this->phoneNumber = (isset($data['phoneNumber'])) ? $data['phoneNumber'] : null;
        $this->residentAddress = (isset($data['residentAddress'])) ? $data['residentAddress'] : null;
        $this->nativePlace = (isset($data['nativePlace'])) ? $data['nativePlace'] : null;
        $this->profilePhoto = (isset($data['profilePhoto'])) ? $data['profilePhoto'] : null;
        $this->description = (isset($data['description'])) ? $data['description'] : null;
    }

    public function getArrayCopy() {
        return get_object_vars($this);
    }

}

?>
